<?php

namespace app\model\training;

use app\BaseModel;
use app\model\RatingScaleModel;
use think\model\relation\BelongsTo;

/**
 * 培训讲座-任务-测评量表
 */
class TrainingTaskRatingScaleModel extends BaseModel
{
    protected $name = 'training_task_rating_scale';

    /**
     * 量表
     * @return BelongsTo
     */
    public function ratingScale(): BelongsTo
    {
        return $this->belongsTo(RatingScaleModel::class,'rating_scale_id')->bind([
            'rating_scale_name' => 'name',
            'rating_scale_cover' => 'cover'
        ]);
    }
}